//
//  TimeFormatterTests.m
//  UnitTests
//
//  Created by Jiang on 2018/11/1.
//  Copyright © 2018 jiang. All rights reserved.
//

#import <XCTest/XCTest.h>

@interface TimeFormatterTests : XCTestCase

@end

@implementation TimeFormatterTests
- (void)testPrint{
    TimeFormatter *formatter = [TimeFormatter twelveFormatter];
    NSString *stamp = [formatter timeStampForStartHour:9 interval:60*30];
    XCTAssertTrue([stamp isEqualToString:@"09:30 AM"]);
    
    formatter = [TimeFormatter twelveFormatter];
    stamp = [formatter timeStampForStartHour:14 interval:60*30];
    XCTAssertTrue([stamp isEqualToString:@"02:30 PM"]);
    
    formatter = [TimeFormatter tweentyFourFormatter];
    stamp = [formatter timeStampForStartHour:14 interval:60*30];
    XCTAssertTrue([stamp isEqualToString:@"14:30"]);
}
@end
